﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using LIMS.Entities;

namespace LIMS.Service
{
    public interface IUserManagementService
    {
        List<User> GetAllUsers();
        List<User> GetAllSortedUsers(string sColumn, string sSortOrder);
        List<Group> GetAllUserGroups();

        bool GetByName(string sName, ref User oUser);

        User GetUser(int Id);

        Group GetUserGroupById(int Id);

        string GetUserPasswordByUserId(int Id);

        User GetUserByUserID(string sUserID);

        bool Save(User oUser);

        bool Delete(User oUser);

        bool SaveUserGroupLink(GroupUserLink oLink);

        bool DeleteUserGroupLink(GroupUserLink oLink);

        GroupUserLink GetUserGroupLinkByIDs(int sUserID, int sGroupId);

        User GetUserByEmailAddress(string EmailAddress);

        bool ResetUserPassword(User oUser,string sUrl);

        User GetUserByPasswordResetHash(string passwordRestHash);

        bool SendUserRegistrationEmails(User newUser);

        List<GroupUserLink> GetUserLinkGroupIdByGroupUserLinkUserId(int iUserId);

        List<GroupPermissionLink> GetUserLinkPermissionLinksByGroupId(int iGroupId);

        List<User> SearchUserByName(string sUserName);
        List<User> GetManagerByDept(string sDeptID, int iUserType);
        List<User> GetSupervisorByManager(string sDeptId, int sChiefSupID, int iUserType);
        List<User> GetAllUsersForGrid(ref GridViewData oGrdData);
    }
}
